package com.bobohost.crmrbac.service.impl;

import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.bobohost.crmrbac.dao.mapper.EmployeeRoleMapper;
import com.bobohost.crmrbac.pojo.po.EmployeeRole;
import com.bobohost.crmrbac.service.EmployeeRoleService;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * <p>
 *  服务实现类
 * </p>
 *
 * @author 叶笑秋
 * @since 2025-05-21
 */
@Service
public class EmployeeRoleServiceImpl extends ServiceImpl<EmployeeRoleMapper, EmployeeRole> implements EmployeeRoleService {

    @Override
    public List<EmployeeRole> findEmployeeRoleListByEmployeeId(Long id) {
        QueryWrapper qw = new QueryWrapper();
        qw.eq("employee_id",id);
        List<EmployeeRole> employeeRoleList = baseMapper.selectList(qw);
        return employeeRoleList;
    }
}
